<div id=tiga_ba>
	<div id=tiga_baa>Edit Tarif Rehabilitasi</div>
	<?php
	$p= new paging ;
		$batas= 10;
		$id_ppk=$_GET['id_ppk'];
	?>
	<div id=tiga_bab>
	<a href="javascript:void(0)" onClick="location.href='utama.php?module=mod_tarif_rehabilitasi&id_ppk=<?php echo $id_ppk;?>'">
		<button class="button">Kembali</button>
	</a></div>
	<div class=clear></div>
</div>
<form action="utama.php?module=mod_tarif_rehabilitasi&id_ppk=<?php echo $_GET['id_ppk'];?>&act=update_semua" method="post">
<table class="tabel">
	<tr>
		<th>NO</th>
		<th>Nama Rehabilitasi</th>
		<th>Tarif</th>
		<th>Tarif Baru</th>
	</tr>
	<?php

		//cek halaman dan posisi halaman
		$posisi = $p ->cariposisi($batas) ;
		$sql="SELECT b.id_tarif,a.id_rehabilitasi as id,a.nama_rehabilitasi ,b.tarif FROM master_rehabilitasi a LEFT JOIN tarif_rehabilitasi b ON a.id_rehabilitasi=b.id_rehabilitasi where nama_rehabilitasi like '%$param_nama%' and id_ppk='$id_ppk' order by nama_rehabilitasi asc limit $posisi,$batas";
		//echo $sql;
		$qry=mysql_query($sql);
		$no= 1;
		if(mysql_num_rows($qry)>0){
		
			while($hasil=mysql_fetch_array($qry)){
	?>
				<tr>
					<td align="center" width="30"><?php echo $no;?></td>
					<td >
					<input type="hidden" name="id_tarif[]" value="<?php echo $hasil['id_tarif'];?>" />
					<?php echo $hasil['nama_rehabilitasi'];?></td>
					<td width="60" align="right"><?php echo format_angka($hasil['tarif']);?></td>
					<td><input name="tarif[]" value="<?php echo $hasil['tarif'];?>" type="text" size="10"/></td>
				</tr>
				
		<?php
				$no++;
			}
		}else{
		?>
	
	<tr>
		<td colspan="7" align="center">Data tidak Ada </td>
	</tr>
	
	<?php
		}
	?>
</table>
<table style="margin: 10px 15px 10px 15px;">
		
		<tr>
			<td>&nbsp;</td>
			<td><input name="submit" type="submit" class="button" value="Simpan" /></td>
		</tr>
	</table> 
</form>
